<?php
class Error {
	
	private $errno;
	private $errstr;
	private $errfile;
	private $errline;
	
	public function __construct($errno, $errstr, $errfile, $errline) {
		$this->errno = $errno;
		$this->errstr = $errstr;
		$this->errfile = $errfile;
		$this->errline = $errline;
	}
	
	public function getErrno() {
		return $this->errno;
	}
	
	public function getErrstr() {
		return $this->errstr;
	}
	
	public function getErrfile() {
		return $this->errfile;
	}
	
	public function getErrline() {
		return $this->errline;
	}
	
	public function __toString(){
		return sprintf("PHP [%s]: %s in %s on line %d", $this->errno, $this->errstr, $this->errfile, $this->errline);
	}
	
}
?>